如果你除了 Gemini CLI 以外還想要裝 Claude Code,那麼最好是安裝 WSL,再從 WSL 啟動 Claude Code,雖然現在可以直接用終端機安裝,但執行起來會有點問題
如果你的 Mac 已經可以執行 npm 指令,就可以跳過這段
npm install -g @google/gemini-cli
C:\Users\你的名字>node -v
v22.19.0
C:\Users\你的名字>npm -v
11.5.2
C:\Users\你的名字>gemini -v
0.4.1
C:\Users\你的名字>gemini
███ █████████ ██████████ ██████ ██████ █████ ██████ █████ █████
░░░███ ███░░░░░███░░███░░░░░█░░██████ ██████ ░░███ ░░██████ ░░███ ░░███
░░░███ ███ ░░░ ░███ █ ░ ░███░█████░███ ░███ ░███░███ ░███ ░███
░░░███ ░███ ░██████ ░███░░███ ░███ ░███ ░███░░███░███ ░███
███░ ░███ █████ ░███░░█ ░███ ░░░ ░███ ░███ ░███ ░░██████ ░███
███░ ░░███ ░░███ ░███ ░ █ ░███ ░███ ░███ ░███ ░░█████ ░███
███░ ░░█████████ ██████████ █████ █████ █████ █████ ░░█████ █████
░░░ ░░░░░░░░░ ░░░░░░░░░░ ░░░░░ ░░░░░ ░░░░░ ░░░░░ ░░░░░ ░░░░░
Tips for getting started:
1. Ask questions, edit files, or run commands.
2. Be specific for the best results.
3. /help for more information.
╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ You are running Gemini CLI in your home directory. It is recommended to run in a project-specific directory. │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
Using: 1 GEMINI.md file
╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ > Type your message or @path/to/file │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
~ no sandbox (see /docs) gemini-2.5-pro (100% context left)